package com.crm.business.crm.mapper;


import com.crm.business.servlet.BaseMapper;
import com.crm.common.crm.entity.BO.CrmRoiPutinPageBO;
import com.crm.common.crm.entity.PO.CrmRoiPutin;
import com.crm.common.crm.entity.VO.CrmRoiStatisVO;
import com.crm.common.ka.core.entity.BasePage;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;


/**
 * <p>
 * 投放消耗表 Mapper 接口
 * </p>
 *
 * @author zhangzhiwei
 * @since 2020-05-21
 */
public interface CrmRoiPutinMapper extends BaseMapper<CrmRoiPutin> {

    BasePage<CrmRoiPutin> queryPageList(BasePage<Object> page, @Param("data") CrmRoiPutinPageBO crmRoiPutin);

    BigDecimal queryListSumMoney(@Param("data") CrmRoiPutinPageBO crmRoiPutin);

    List<Map<String, Object>> selectAllPutinStatis();

    BigDecimal querySumMoney(@Param("putinPlatform") String putinPlatform,@Param("startPutinFormDate") String startPutinFormDate,@Param("endPutinFormDate") String endPutinFormDate);

    List<CrmRoiStatisVO> queryPutinStatisForData(@Param("startPutinFormDate") String startPutinFormDate,@Param("endPutinFormDate") String endPutinFormDate);

    List<CrmRoiStatisVO> queryPutinStatisByFormDate(@Param("data") CrmRoiPutinPageBO crmRoiPutin);

    List<CrmRoiStatisVO> queryPutinStatisForYearsSource(@Param("startPutinFormDate") String startPutinFormDate,@Param("endPutinFormDate") String endPutinFormDate);


}
